<template>
    <div class="formUpdate">
        <div class="top">
            <div class="title"><span>*</span>上传{{title}}</div>
            <cube-upload :auto="false" @input="filesAdded"/>
        </div>
        <div class="bottom">
            <span >*图片大小≤{{imgSize}}</span>
            <span v-if="videoSize!==undefined">;视频大小≤{{videoSize}}Mb</span>
        </div>
    </div>
</template>

<script>
    export default {
        name : "index",
        props:{
            title:String,
            imgSize:String,
            videoSize:Number
        },
        methods:{
            filesAdded(files){
                this.$emit('getUpdateList',files)
            }
        }
    }
</script>

<style scoped lang="stylus">
    .formUpdate
        background-color  #fff
        .top
            padding  0.40rem
            border-bottom 0.02rem solid #EEEEEE
            .title
                color #333333
                font-size 0.40rem
                margin-bottom 0.17rem
                span
                    font-size 0.29rem
                    color #00A398
        .bottom
            padding  0.40rem
            color #999999
            font-size 0.24rem
</style>